package com.ljc.dao;

import com.ljc.entity.DeviceContract;
import com.ljc.vo.DeviceContractSearch;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;
import org.springframework.stereotype.Service;

import java.util.List;

@Mapper
@Repository
public interface DeviceContractDao {


    void add(DeviceContract deviceContract);

    List<DeviceContract> searchByUser(DeviceContractSearch search);

    @Select("select * from device_contract where id =#{id}")
    DeviceContract findOne(int id);


    void update(DeviceContract deviceContract);
    @Delete("delete from device_contract where id=#{id}")
    void delete(int id);
    List<DeviceContract> searchByAdmit(DeviceContractSearch search);

}
